/*
 Navicat Premium Data Transfer

 Source Server         : 127.0.0.1
 Source Server Type    : MySQL
 Source Server Version : 50730
 Source Host           : localhost:3306
 Source Schema         : spring_cloud

 Target Server Type    : MySQL
 Target Server Version : 50730
 File Encoding         : 65001

 Date: 31/03/2021 17:37:29
*/

SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;

-- ----------------------------
-- Table structure for goods
-- ----------------------------
DROP TABLE IF EXISTS `goods`;
CREATE TABLE `goods` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `name` varchar(255) DEFAULT NULL,
  `category` varchar(255) DEFAULT NULL,
  `price` double(10,2) DEFAULT NULL,
  `num` int(11) DEFAULT NULL,
  `status` int(255) DEFAULT NULL COMMENT '0: 下架；1：上架',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=19 DEFAULT CHARSET=utf8;

-- ----------------------------
-- Records of goods
-- ----------------------------
BEGIN;
INSERT INTO `goods` VALUES (1, 'iphone4', 'phone', 1699.00, 100, 1);
INSERT INTO `goods` VALUES (2, 'iphone5', 'phone', 3999.00, 99, 1);
INSERT INTO `goods` VALUES (3, 'iphone5s', 'phone', 4299.00, 99, 1);
INSERT INTO `goods` VALUES (4, 'iphone6', 'phone', 4999.00, 100, 1);
INSERT INTO `goods` VALUES (5, 'iphone7', 'phone', 5299.00, 120, 1);
INSERT INTO `goods` VALUES (6, 'iphone8', 'phone', 6399.00, 199, 1);
INSERT INTO `goods` VALUES (7, 'iphoneX', 'phone', 6999.00, 299, 1);
INSERT INTO `goods` VALUES (8, '可口可乐', 'food', 3.00, 999, 1);
INSERT INTO `goods` VALUES (9, '百事可乐', 'food', 3.00, 999, 1);
INSERT INTO `goods` VALUES (10, '乐事薯片', 'food', 8.00, 888, 1);
INSERT INTO `goods` VALUES (11, '泡椒凤爪', 'food', 10.00, 666, 1);
INSERT INTO `goods` VALUES (12, '统一泡面', 'food', 4.00, 888, 1);
INSERT INTO `goods` VALUES (13, '火腿肠', 'food', 2.50, 555, 1);
INSERT INTO `goods` VALUES (14, '衬衫', 'cloth', 78.00, 300, 1);
INSERT INTO `goods` VALUES (15, '鞋', 'cloth', 199.00, 200, 1);
COMMIT;

-- ----------------------------
-- Table structure for orders
-- ----------------------------
DROP TABLE IF EXISTS `orders`;
CREATE TABLE `orders` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `goods_id` int(11) DEFAULT NULL COMMENT '商品id',
  `create_time` varchar(255) DEFAULT NULL,
  `status` int(255) DEFAULT NULL COMMENT '0未支付；1已支付；2已失效；3已删除',
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=13 DEFAULT CHARSET=utf8;

-- ----------------------------
-- Records of orders
-- ----------------------------
BEGIN;
INSERT INTO `orders` VALUES (1, 3, '2021-3-30', 1);
INSERT INTO `orders` VALUES (2, 6, '2021-3-30', 0);
INSERT INTO `orders` VALUES (3, 7, '2021-3-29', 1);
INSERT INTO `orders` VALUES (4, 7, '2021-3-3', 1);
INSERT INTO `orders` VALUES (5, 8, '2021-3-19', 1);
INSERT INTO `orders` VALUES (6, 8, '2021-2-8', 1);
INSERT INTO `orders` VALUES (7, 8, '2021-3-28', 1);
INSERT INTO `orders` VALUES (8, 9, '2021-3-19', 1);
INSERT INTO `orders` VALUES (9, 12, '2021-3-4', 1);
INSERT INTO `orders` VALUES (10, 13, '2021-3-5', 1);
INSERT INTO `orders` VALUES (11, 13, '2021-3-5', 1);
INSERT INTO `orders` VALUES (12, 15, '2021-3-30', 1);
COMMIT;

-- ----------------------------
-- Table structure for products
-- ----------------------------
DROP TABLE IF EXISTS `products`;
CREATE TABLE `products` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `NAME` varchar(50) DEFAULT NULL,
  `price` double DEFAULT NULL,
  `flag` varchar(2) DEFAULT NULL,
  `goods_desc` varchar(100) DEFAULT NULL,
  `images` varchar(400) DEFAULT NULL,
  `goods_stock` int(11) DEFAULT NULL,
  `goods_type` varchar(20) DEFAULT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=2 DEFAULT CHARSET=utf8;

-- ----------------------------
-- Records of products
-- ----------------------------
BEGIN;
INSERT INTO `products` VALUES (1, 'iPhone 12', 7599, '1', '256G', 'https://store.storeimages.cdn-apple.com/8756/as-images.apple.com/is/iphone-12-family-select-2020?wid=940&amp;hei=1112&amp;fmt=jpeg&amp;qlt=80&amp;.v=1604343709000', 999, '1');
COMMIT;

SET FOREIGN_KEY_CHECKS = 1;
